//
//  FCBaseNavigationVC.m
//  FundChain
//
//  Created by 肖浩然的mac on 2018/2/6.
//  Copyright © 2018年 RUIXIN. All rights reserved.
//

#import "FCBaseNavigationVC.h"
#import "UIImage+Image.h"
@interface FCBaseNavigationVC ()

@end

@implementation FCBaseNavigationVC

+(void)initialize
{
    if (self==[FCBaseNavigationVC class]) {
       
        //外观的设置
        //0. 获取导航栏的实例
        UINavigationBar *bar=[UINavigationBar appearance];
        //1.设置导航栏的背景图
//        UIImage *imageNavBack =[UIImage BgImageFromColors:@[kWhiteColor,kWhiteColor] withFrame:CGRectMake(0, 0, SCREEN_WIDTH, 64)];
        UIImage *imageNavBack =[UIImage imageNamed:@"bg_login_top"];
        [bar setBackgroundImage:imageNavBack forBarMetrics:(UIBarMetricsDefault)];
        
        
        //去掉导航栏下面的细线（必须设置背景图片，不能setBarTintColor）
        bar.shadowImage = [[UIImage alloc] init];
        
        [bar setBarStyle:(UIBarStyleBlack)];
        
        //barTintColor背景色; tintColor是barButtonItem颜色; titleTextAttributes是标题颜色
        [bar setTintColor:kWhiteColor];//左右按钮的颜色 白色
        
//        [bar setBarTintColor:kRedOrangeColor];
        
        NSMutableDictionary *attributes=[NSMutableDictionary dictionary];
        attributes[NSForegroundColorAttributeName]=kWhiteColor;
        attributes[NSFontAttributeName] = [UIFont systemFontOfSize:22];
        [bar setTitleTextAttributes:attributes];
        
    }
}
- (void)viewDidLoad {
    [super viewDidLoad];
   
}


@end
